﻿// Copyright (c) MichaConrad. All rights reserved. See License.txt in the project root for license information.

namespace LinqToLdapExtensions.Domain
{
    using System.Diagnostics.CodeAnalysis;

    using LinqToLdap.Mapping;

    /// <summary>
    /// The organizational unit.
    /// </summary>
    [DirectorySchema("", ObjectClass = "inetOrgPerson")]
    public class InetOrgPerson
    {
        /// <summary>
        /// Gets or sets the distinguished name.
        /// </summary>
        [DistinguishedName]
        public string DistinguishedName { get; set; }

        /// <summary>
        /// Gets or sets the uid.
        /// </summary>
        [SuppressMessage("StyleCop.CSharp.DocumentationRules", "SA1650:ElementDocumentationMustBeSpelledCorrectly", Justification = "Reviewed. Suppression is OK here.")]
        [DirectoryAttribute("uid")]
        public string Uid { get; set; }

        /// <summary>
        /// Gets or sets the first name.
        /// </summary>
        [DirectoryAttribute("sn")]
        public string FirstName { get; set; }

        /// <summary>
        /// Gets or sets the last name.
        /// </summary>
        [DirectoryAttribute("givenname")]
        public string LastName { get; set; }

        /// <summary>
        /// Gets or sets the display name.
        /// </summary>
        [DirectoryAttribute("cn")]
        public string DisplayName { get; set; }
        
        /// <summary>
        /// Gets or sets the e mail.
        /// </summary>
        [DirectoryAttribute("mail")]
        public string EMail { get; set; }

        /// <summary>
        /// Gets or sets the phone number.
        /// </summary>
        [DirectoryAttribute("telephonenumber")]
        public string PhoneNumber { get; set; }

        /// <summary>
        /// Gets or sets the manager.
        /// </summary>
        public InetOrgPerson Manager { get; set; }
    }
}
